<!DOCTYPE html>
<html lang="ch">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<form action="#" method="get">
    用户名：<input type="text" placeholder="请输入用户名" name="username"><br>
    密码：<input type="password" name="password" placeholder="请输入密码"><br>
    性别：<input type="radio" name="gender" checked="checked" value="male">男
         <input type="radio" name="gender" value="female">女 <br>
        <input type="checkbox" name="hobby" value="shopping"> 购物<br>
    图片：<input type="file" name="pic"> 上传图片
    <script>
        var reg = new RegExp("\w{6,12}");
        var reg2 = /w{6,12}/;
        alert(reg);
        alert(reg2);
    </script>

</form>

</body>
</html>